﻿using EntityMode;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;
using MySqlX.XDevAPI.Common;

namespace PartyWorkSupervise.Controllers
{
    [Route("api/[controller]")]
    [ApiController]
    public class EmployeeController : ControllerBase
    {
        private readonly PWSDbcontext db;
        public EmployeeController(PWSDbcontext contet)
        {
            db = contet;
        }
        [HttpGet]
        public List<Employee> Get()
        {
            return db.employee.ToList();
        }
        //[HttpGet("lable_poverty")]
        //public object Get(bool lable_poverty)
        //{
        //    People people = db.people.Where(w => w.lable_poverty == lable_poverty).FirstOrDefault<People>();
        //}
    }
}
